import {
    service
} from "../request/request";

/* 全部订单 start */
export function orderList(param) {
    return service({
        url: `/order/list`,
        method: 'post',
        data: {
            ...param
        }
    })
}
/* 全部订单  end  */
/**
 * 修改价格
 */
export function orderItemUpdatePrice(param) {
    return service({
        url: `/orderItem/updatePrice`,
        method: 'post',
        data: {
            ...param.orderList
        },
        param: {
            grade: param.grade
        }
    })
}
/**
 * 取消订单
 */
export function orderCancelOrder(param) {
    return service({
        url: `/order/cancelOrder`,
        method: 'post',
        data: {
            ...param
        },
        param: {
            grade: param.grade
        }
    })
}
/**
 * 查看原因接口
 */
export function orderViewReason(param) {
    return service({
        url: `/order/findCancelReason`,
        method: 'get',
        params: {
            ...param
        }
    })
}
/**
 * 订单详情接口
 */
export function orderDetails(param) {
    return service({
        url: `/order/findDetail`,
        method: 'get',
        params: {
            ...param
        }
    })
}
/**
 * 打印
 */
export function getPrintOrder(param) {
    return service({
        url: `/order/print`,
        method: 'get',
        params: {
            ...param
        }
    })
}
/**
 * 批量打印
 */
export function printsOrder(param) {
    return service({
        url: `/order/batchPrint`,
        method: 'get',
        params: {
            ...param
        }
    })
}